package so.ifl.servcie.impl;

import java.util.List;

import java.util.Map;

import org.apache.ibatis.session.RowBounds;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import so.ifl.dao.ConsultInfoDao;
import so.ifl.servcie.ConsultService;
import so.ifl.vo.ConsultVo;

/**
 * 
 * create by simon
 * create at 2011-12-26 下午9:28:43
 * <mailto:liangyuanliu@gmail.com>
 */
@Service("consultService")
public class ConsultServiceImpl implements ConsultService {
	@Autowired
	private ConsultInfoDao consultInfoDao;

	public List<ConsultVo> queryConsultWithTimeToRemind(
			Map<String, Object> param , Integer offset, Integer limit) {
		return consultInfoDao.queryConsultWithTimeToRemind(param,new RowBounds(offset, limit));
	}
	public int countConsultWithTimeToRemind(Map<String, Object> param) {
		return consultInfoDao.countConsultWithTimeToRemind(param);
	}

	public List<ConsultVo> queryConsultWithParamAndPagination(
			Map<String, Object> params, Integer offset, Integer limit) {
		return consultInfoDao.queryConsultWithParamAndPagination(params,
				new RowBounds(offset, limit));
	}

	public int countConsultWithParam(Map<String, Object> param) {
		return consultInfoDao.countConsultWithParam(param);
	}

	public void insertConsult(Map<String, Object> param) {
		consultInfoDao.insertConsult(param);

	}

	public void updateConsult(Map<String, Object> param) {
		consultInfoDao.updateConsult(param);

	}

	public void deleteConsult(Integer companyId) {
		consultInfoDao.deleteConsult(companyId);
	}

	

}
